
public class Person {
	String name;
	int health, dexterity, accuracy;
	String target;
	Weapon weapon;
	boolean isDead;
	
	public Person(String name, int health, int dexterity, int accuracy)
	{
		this.name = name;
		this.health = health;
		this.dexterity = dexterity;
		this.accuracy = accuracy;
		this.isDead = false;
	}
	
	public String getName()
	{
		return name;
	}
	
	public int getHealth()
	{
		return health;
	}
	
	public int getDexterity()
	{
		return dexterity;
	}
	
	public int getAccuracy()
	{
		return accuracy;
	}
	
	public int doDamage(Person personToDamage, int damageToDo, Bodypart partToHit)
	{
		int damage = personToDamage.health -= damageToDo * partToHit.damageMultiplier;
		return damage;
	}
	
	public boolean isDead(Person personToCheck)
	{
		return personToCheck.isDead;
	}
	
	public boolean checkForDeath(Person personToCheck)
	{
		if(personToCheck.health <= 0)
		{
			//Person Dead
			personToCheck.isDead = true;
			return true;
		}else
		{
			personToCheck.isDead = false;
		}
		return false;
	}
	
	public void setWeapon(Weapon selectedWeapon)
	{
		weapon = selectedWeapon;
	}
	
	public Weapon getAWeapon()
	{
		return weapon;
	}
	
	public int getWeapon()
	{
		return weapon.getWeaponId();
	}
	
	public String getWeaponName()
	{
		return weapon.getWeaponName();
	}
}
